Quantcast
Channel: MCS Electronics Forum
Viewing all 20568 articles
Browse latest View live

BASCOM-AVR : Serial over Ethernet : NEWTOPIC

$
0
0
Has anyone implemented a serial over ethernet converter using the W5200 or other Wiznet device? I did a quick search and could not find a thread on the topic. I would like to replace an expensive Lantronix Xport ($50) with a W5200, Magjack and a bit of software (Hardware < $10) Thanks! [b:86274812b0][color=red:86274812b0](BASCOM-AVR version : 2.0.7.7 )[/b:86274812b0][/color:86274812b0]

BASCOM-AVR : Serial over Ethernet : REPLY

$
0
0
Hello rkumetz The lantronix devices are expensive try looking at the VRM04 many more features just google it. I have implemented TCPIP get & post to serial with my web servers but not the virtual serial port that the VRM04 implements, along with wifi, router and access point. I have not had time to work with it yet so it would be good to see some code of the avr using the VRM04. Regards Paul

BASCOM-AVR : Serial over Ethernet : REPLY

$
0
0
hello Paul, [quote:0ae1a86472]I have implemented TCPIP get & post to serial with my web servers[/quote:0ae1a86472] do you have any sample for request/response html via serial port regards Bojan

Various : USB-ISP on Windows 8.1 : REPLY

$
0
0
Just a reaction that I managed to succesfully install the driver i downloaded from the MCSelec.com site, MCS Shop(48), Programmers(4), scroll down to USB-ISP and select programmer product details, again scroll down and hit "You can download drivers also here" Now to succesfully install the driver switch off the signature verification in Win 8.1 as follows: Hit the Windos key + "C" Settings Change PC settings Update and recovery Advanced startup Restart now (system re-starts) Troubleshoot Advanced options Startup settings Restart [F7] (this is the function key "F7" (system re-starts) Don't forget to check you've selected the correct programmer in Bascom, options, programmer, USB-ISP Programmer Good luck!

BASCOM-AVR : Serial over Ethernet : REPLY

$
0
0
Hello Bojan In the blog section you will find my two web server projects. I have code that sends data to the serial port as a command or sends text to the serial port entered on a web page. You can also send a get or post command from a program on a computer with the same result. What are you trying to do? Regards Paul

BASCOM-AVR : Serial over Ethernet : REPLY

$
0
0
Hello Bojan, I'm using the WZNet110 module, which is completely self contained and costs around 30 Euro. We have several units operating for more than 1 year now - without any problems. Good luck Ernst

BASCOM-AVR : Serial over Ethernet : REPLY

$
0
0
Hello Ernst, Now I trying to make a code for USR-WIFI232. I have some problems, because i have problem with html code :) Module is very small and good for any configuration. [url]http://en.usr.cn/download/USR-WIFI232-T.pdf[/url] [url]http://www.ebay.com/itm/USR-WIFI232-T-Tiny-Size-Low-Power-Uart-TTL-TO-802-11B-G-N-Low-Price-Wifi-Module-/251594619856?pt=LH_DefaultDomain_0&hash=item3a94353bd0[/url] regards, Bojan

BASCOM-AVR : Serial communication isr : REPLY

$
0
0
Hello i.dobson, Thank You. I will test it and give feedback Regards toto

BASCOM-AVR : Serial communication isr : REPLY

$
0
0
Ian, i guess this is for hardware UART.... if i would use software UART, i guess i would need to use pin change interrupt, right? Would this same routine work in that case?

BASCOM-AVR : 10-bit ADC, bipolar : NEWTOPIC

$
0
0
Hi, I am using a 10-bit ADC in bipolar mode (Attiny). In order to handle negative values, I use this (from Galahat): [code:1:53e4e009a3] W1 = Adc 'integer If W1.9 = 1 Then W1 = W1 Or &HFE00[/code:1:53e4e009a3] At 14MHz, the first line take about 1µs, whereas the second line if condition is met takes 200µs. That appears to be waist of time since I need to get as many samples/s as possible. Does somebody know a faster conversion method (maybe assembler code)? Tanks for any help, Meister [b:53e4e009a3][color=red:53e4e009a3](BASCOM-AVR version : 2.0.7.7 )[/b:53e4e009a3][/color:53e4e009a3]

BASCOM-AVR : 10-bit ADC, bipolar : REPLY

$
0
0
[code:1:dc8d04d8e5]Dim W1 As Integer Dim W1_h As Byte At W1 + 1 Overlay 'Schneller Zzgriff auf das High-Byte W1 = ADC $asm LDS r24,{W1_h} 'Lade hibyte SBRC R24,1 'Überspringe nächste Anweisung bei W1_h.1 = 0 (also W1.9 = 0) ORI r24,&HFE 'Or $FE STS {W1_h},r24 'Sichern, fertig. Dauert 4 Zyklen, also 0,28µs bei 14MHz $end Asm[/code:1:dc8d04d8e5]

BASCOM-AVR : 10-bit ADC, bipolar : REPLY

$
0
0
BTW, [code:1:ce9ccc69a8]If W1.9 = 1 Then W1 = W1 Or &HFE00[/code:1:ce9ccc69a8] takes 20 Cycles = 1,4µs in simulator. 200µs wouldn't make any sense.

BASCOM-AVR : Serial communication isr : REPLY

$
0
0
Hi, Sorry but I've not used a Software Serial Input. Using a pin Change Interrupt might work but every time a character is received the CPU will be blocked/stay in the ISR until the character is received. You should use a Hardware UART when ever possible. Regards Ian Dobson

BASCOM-AVR : Serial communication isr : REPLY

$
0
0
Sure, i understand. It's just that recently i needed more than one UART and since i used mega8, i've had no choice but to use SW one... And, you're right...in SW one CPU is indeed blocked for the time of receiving data, but since receiving data was the main thing, in my case this was acceptable... Thanks!

BASCOM-AVR : 10-bit ADC, bipolar : REPLY

$
0
0
Hello laboratory rat , (translated by Google) Thank you very much for the assembler code. I try it out later. So, I might gain ~1µs: Concerning the timings: You were right. I probably missed to delete a Wait statement.... I tested this way: [code:1:ea4c0a650e]'ADC free running Pinb.2 = 1 'toggle PortB.2 (Tiny841) W1 = Adc if W1.9 = 1 Then W1 = W1 Or &HFE00 End If Pinb.2 = 1[/code:1:ea4c0a650e] The logic analyzer measures 2.5µs including reading the ADC. Only reading takes ~1µs so the simulator result looks fine. But, the conversion time is much, much less than 200µs, should be about 1µs (~10-20 cycles), right? Greetings, Meister

BASCOM-AVR : 10-bit ADC, bipolar : REPLY

$
0
0
[quote:f3c00387b8="Meister"][code:1:f3c00387b8]'ADC free running[/code:1:f3c00387b8] But, the conversion time is much, much less than 200µs, should be about 1µs (~10-20 cycles), right?[/quote:f3c00387b8] If you have configured the ADC via Config ADC = FREE, the GetADC() routine is altered and doesn't wait for a conversion result, instead it simply reads ADCL/ADCH. This takes some cycles too, but its speed doesn't depend on the ADC. Disadvantage is: you never know, how old the last conversion result is, as the ADC continuously converts and the GetADC() just reads the latest available result. The speed of the ADC however depends on its prescaler setting. If the prescaler clock is too low, the result in free-run may be not very actual at the time it is read, if this clock is too high, you loose accuracy.

BASCOM-AVR : Question about Format : NEWTOPIC

$
0
0
I will like that the variable (dcf_bits) is showed as an binnare string on my Display. but Bascom it's gif an error: [b:3eb19af7e6]SUB or FUNCION not declared [put_string Bin][/b:3eb19af7e6] F = Str(dcf_bits) F = Format(f , "00000000") Call Move_cursor(48 , 32) : Call Text_font(0) : Call Text_forground(white) : Call Put_string Bin(f) Does anyone how to...... Thanx [b:3eb19af7e6][color=red:3eb19af7e6](BASCOM-AVR version : 2.0.7.7 )[/b:3eb19af7e6][/color:3eb19af7e6]

BASCOM-AVR : 10-bit ADC, bipolar : REPLY

$
0
0
Yes, with a tiny841 a conversation takes 15 cycles, but ADC clock cycles. If you want to have 10 Bit resolution, the maximum clockrate for ADC is 200kHz. ADC clock comes from system clock through a prescaler, on a 14 MHz BASCOM will choose a prescaler of 128 (-> 137µs). You can manually set the prescaler - see help "config adc". You can go faster (up to 1Mhz) but you will loose precision. Maybe a prescaler of 64 is uncritical in your application. Of course your program can do other things while adc is in free running mode.

BASCOM-AVR : Question about Format : REPLY

$
0
0
then bin() function returns a string when you pass it a numeric value. you must not pass it a string.

BASCOM-AVR : 10-bit ADC, bipolar : REPLY

$
0
0
[quote:4e7912c0e0] but ADC clock cycles[/quote:4e7912c0e0] Thanks to both of you for the clarifications. I was'nt aware of that but always I had a bad feeling about the consequences of the ADC timings - which was not important until now. At present I try to eliminate residual [i:4e7912c0e0]periodic [/i:4e7912c0e0]~1MHz "noise" by averaging many ADC readings - with disappointing results. Maybe single conversion will do better in this case. I will try.
Viewing all 20568 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>