Okay.... mscomm.ocx didnt show zero :((( have to check it... thank you very much
↧
BASCOM-AVR : want to transfer eeprom via UART to PC... Problem with binar : REPLY
↧
BASCOM-AVR : want to transfer eeprom via UART to PC... Problem with binar : REPLY
To use mscomm.ocx in binary mode you have to setup it up something like this.
[code:1:1a5508b6d1]
MSComm1.InputMode = comInputModeBinary
[/code:1:1a5508b6d1]
↧
↧
BASCOM-AVR : Programming Adafruit Feather 32u4 Adalogger : REPLY
Thanks Mark & Evert,
"myAVR MK2 / AVR910" works well. I have 5 seconds after I push the reset button on the Adafruit to initiate a "download". The bootloader comes up as COM7 (in my case) then after the 5 sec timeout, the come port falls back to COM6.
As far as 910 / 109 is concerned, they both look the same after a couple of glasses of wine ... but who is counting?
Cheers!
↧
BASCOM-ARDUINO : uno and maga2560 drawing of correlation of the pinout : REPLY
Bonjour,
simply i would like to say merci bien, i use a arduino mega and the drawings are very helpful for me!
Ingolf
↧
BASCOM-AVR : E-Paper EPA20-A : REPLY
Hello Mark,
thanks for the link !
That helps :)
Best regards,
Greece2001
↧
↧
BASCOM-AVR : want to transfer eeprom via UART to PC... Problem with binar : REPLY
Hi,
i used inputmode binary and also nulldiscard to false. when I use print chr(0) vb6 app didnt receive anything. Maybe it could be problem with bluetooth modul? I use HC-05 modul for data-transfer.
Cheers
↧
BASCOM-AVR : Programming Adafruit Feather 32u4 Adalogger : REPLY
[quote:17282527cb]Looks the same, but the numbers are in a different order Wink [/quote:17282527cb]
Oeps :oops: . Missed that totally. All those years i read it as the same number. Good that somebody is awake :D
But nice that it works.
↧
BASCOM-AVR : want to transfer eeprom via UART to PC... Problem with binar : REPLY
both print and printbin send ascii values from 0-255.
i think you can simply solve it by sending data as hex using : print hex(myByte)
then all you need to do is to 'decode' the hex ascii data back with a loop like
for b=1 to len(someString) step 2
s=mid(s,b,2)
bytevalue=val("&H" + s)
next
↧
BASCOM-ARDUINO : arduino mega (2560) + ethernet shield(Wiz5500) @ bascom 2.0. : NEWTOPIC
Hi bascom colleagues,
....recently i came in contact with arduino "ready to use" modules , previous i was used to design myself hardware by pcb and atmega chips.
the target is, to realize a small webserver with this arduino mega and an arduino ethernet shield 2, which contains the Wiz5500 chip.
after many many hours of troubleshooting, reading and also trying all relevant posts in bascom and arduino forums, which often are contradictionary statements,
i never have successful established this hardware combination.
regarding bascom, i used the wiz5200 lib..... have dealt the hardware in various configs as in forums discussed, but none of these variations has worked.
in general, it is alway possible to download and the devices run itself, the megaboard always runs and the ethernet shield acts ( led indication ) on pings,
( but never the ping was successful responsed...) typical message is : "antwort von 10.100.10.1: Zielhost nicht erreichbar" ( 10.100.10.1 is my PC IP, may be unusual but
necessary because of other industrial ethernet based test components... ) the arduino IP i have set to be in same range of adress and submask....
but they do never walk together, even simply added via connector or, with separate spi wires and ports lowered as in forums often described. I stuck here...
with arduino i experienced only one two examples, because i do not like the rudimentary IDE and the language as well. It ist a backstep of level comparing to bascom im my view.
after all, my simple question is, does anybody of you have successful run an arduino mega with ethernet2 shield on bascom? If yes, any hints how to make it, are
highly appreciated.
thanks a lot for any comment or advice
Ingolf
↧
↧
BASCOM-AVR : want to transfer eeprom via UART to PC... Problem with binar : REPLY
Hi Mark,
i solved it. In VB6 input of mscomm must gone into an array. Than it will work :)
Cheers
↧
BASCOM-ARDUINO : arduino mega (2560) + ethernet shield(Wiz5500) @ bascom 2.0. : REPLY
i think the samples folder contains samples using arduino hardware.
using w3100,w5100,w5200,w5300 and w5500 chips i never had a problem. i also made a converter board for the wiz810mj module.
using some of the tcp shields i did had problems. for example because of a buffer that had to be switched. or because of bad contacts in the headers.
i found arduino hardware nice for proto but not for production.
There is also a lot of variation between the arduino boards and the shields.
I advise to start very simple. Just pick a simple sample from bascom and get the PING working.
I do not know if w5500 has echo enabled by default (some wiz chips have the option to turn off ping).
post the circuit of the shield you want to use.
for w5500 an init like this is required:
Config Tcpip = Noint , Mac = 12.128.12.34.56.78 , Ip = 192.168.1.88 , Submask = 255.255.255.0 , Gateway = 192.168.1.1 , Localport = 1000 , [b:35d87482ba]Chip = W5500 [/b:35d87482ba], Spi = Spie , Cs = Porte.4
Print "Init Done"
The gateway is important. and the submask too.
while a web server is relatively simple, you should have the ping going first.
↧
BASCOM-ARDUINO : uno and maga2560 drawing of correlation of the pinout : REPLY
thanks for the post ingolf !
I saw your other post about Ethernet, I must say I know nothing about this protocol, As said Mark It is a question of Ping... why not Pong ! :lol:
JP :wink:
↧
New WebSite : just test : REPLY
tested
regards
Joachim
↧
↧
BASCOM-ARDUINO : arduino mega (2560) + ethernet shield(Wiz5500) @ bascom 2.0. : REPLY
- this stuff i work with and how : ----------------------------------------------------------------------------------
used Bascom Version: 2.0.7.8.001
used Hardware: ArduinoMega 2560 PCB Revision V3E
Arduino Ethernetshield2, PCB Revision ETH11 V2
used programming method: STK500 and ISP header of arduino board / no bootloader
------------------------------------------------------------------------------------------------------------
Hi Marc, thank you for fast response, i am going to workout now step by step....
from the Bascom examples ping_WS5300.bas i simply derived the code and changed the config TCPIP:
Config Tcpip = Noint , Mac = 12.128.12.34.56.78 , Ip = 192.168.1.88 , Submask = 255.255.255.0 , Gateway = 192.168.1.1 , Localport = 1000 , Chip = W5500 , Spi = Spie , Cs = Porte.4
compiler complaints "Invalid parameter for CONFIG parameter or Value [WS5500] in C:\pathping_ardumega2560_ethernetshiled2_V0.1.bas"
i checked then updates to bascom 2.0.7.9 ( having the valid lic file for 2.0.7.9 in directory ) but update wizard found nothing to do.
so whats the reason why compiler complains about the W5500?
add: attached the schematic of the used arduino ethernet shield
↧
BASCOM-ARDUINO : arduino mega (2560) + ethernet shield(Wiz5500) @ bascom 2.0. : REPLY
i added the schematic of ethernet shield // since *. pdf or eagle *.sch are not denied to upluad here, i had to rename it to *.bas, to be able to attach it here, please rename it after download to PDF!!
↧
BASCOM-ARDUINO : arduino mega (2560) + ethernet shield(Wiz5500) @ bascom 2.0. : REPLY
for w5500 you should update. download the full setup from register.mcselec.com (see help topic move to new pc)
the circuit : there is an sd card intreface on it. so you use 2 SS signals.
Just make sure you use the correct spi signal for the w5500. which means you must measure between the micro port pin you use as SS and the w5500 IO10*/SS to see if they match/are connected.
here is a sample for w5500 and xmega. you need to change the spi for normal xmega. but you can grab that from a w5100 sample.
[code:1:025285824e]
'-----------------------------------------------------------------------------------------
'name : sntp_W5500.bas RFC 2030
'copyright : (c) 1995-2015, MCS Electronics
'purpose : test SNTP() function
'micro : xMega128A1
'suited for demo : no, needs library only included in the full version
'commercial addon needed : no
'-----------------------------------------------------------------------------------------
$regfile = "xm64a3def.dat"
$crystal = 32000000
$hwstack = 64 ' default use 32 for the hardware stack
$swstack = 128 'default use 10 for the SW stack
$framesize = 64 'default use 40 for the frame space
'First Enable The Osc Of Your Choice
Config Osc = Enabled , 32mhzosc = Enabled
'configure the systemclock
Config Sysclock = 32mhz , Prescalea = 1 , Prescalebc = 1_1
'configure UART
Config Com1 = 19200 , Mode = Asynchroneous , Parity = None , Stopbits = 1 , Databits = 8
Config Spie = Hard , Master = Yes , Mode = 0 , Clockdiv = Clk32 , Data_order = Msb , Ss = Auto
'SPI on Port E is used
'portx.7 - SCK
'portx.6 - MISO
'portx.5 - MOSI
'portx.4 - SS
Waitms 1000
Print "Init , set IP to 192.168.1.88" ' display a message
Config Tcpip = Noint , Mac = 12.128.12.34.56.78 , Ip = 192.168.1.88 , Submask = 255.255.255.0 , Gateway = 192.168.1.1 , Localport = 1000 , Chip = W5500 , Spi = Spie , Cs = Porte.4
Print "Init Done"
$lib "datetime.lbx" 'this example uses date time routines
Dim Ip As Long ' IP number of time server
Dim Idx As Byte ' socket number
Dim Lsntp As Long ' long SNTP time
Print "SNTP demo"
'assign the IP number of a SNTP server
Ip = Maketcp(129.6.15.30 ) 'assign IP num NIST time.nist.gov port 37
Print "Connecting to : " ; Ip2str(ip)
'we will use Dutch format
Config Date = Dmy , Separator = Minus
'we need to get a socket first
'note that for UDP we specify sock_dgram
Idx = Getsocket(idx , Sock_dgram , 5000 , 0) ' get socket for UDP mode, specify port 5000
Print "Socket " ; Idx
'UDP is a connection less protocol which means that you can not listen, connect or can get the status
'You can just use send and receive the same way as for TCP/IP.
'But since there is no connection protocol, you need to specify the destination IP address and port
'So compare to TCP/IP you send exactly the same, but with the addition of the IP and PORT
'The SNTP uses port 37 which is fixed in the tcp asm code
Do
Waitms 5000
Lsntp = Sntp(idx , Ip) ' get time from SNTP server
' Print Idx ; Lsntp
'notice that it is not recommended to get the time every sec
'the time server might ban your IP
'it is better to sync once or to run your own SNTP server and update that once a day
'what happens is that IP number of timer server is send a diagram too
'it will put the time into a variable lsntp and this is converted to BASCOM date/time format
'in case of a problem the variable is 0
Print Date(lsntp) ; Spc(3) ; Time(lsntp)
Loop
End[/code:1:025285824e]
like this :
[code:1:025285824e]Config Spi = Hard , Interrupt = Off , Data_order = Msb , Master = Yes , Polarity = Low , Phase = 0 , Clockrate = 4 , Noss = 0
'Init the spi pins
Spiinit
'we specify IP 0.0.0.0 and gateway 255.255.255.255. Really important is to use local port 68 !
Config Tcpip = Noint , Mac = Mac_add(1) , Ip = 0.0.0.0 , Submask = 255.255.255.0 , Gateway = 255.255.255.255 , Localport = 68 , Tx = $55 , Rx = $55 , Chip = W5100 , Spi = 1
Print "Init"
[/code:1:025285824e]
above sample was from a dhcp so do fill in IP , mac
optional you can check with a led on the SS pin if it is selected.
↧
BASCOM-AVR : Bascom and CI SEMTECH sx1276.. sx1278 : NEWTOPIC
hello,
Somebody did etwas with the CI SX1276 or SX1278 product of SEMTECH?
i have a problem to read the RX FIFO
[b:3e5805e433][color=red:3e5805e433](BASCOM-AVR version : 2.0.7.8 , Latest : 2.0.7.8 )[/b:3e5805e433][/color:3e5805e433]
↧
↧
BASCOM-ARDUINO : arduino mega (2560) + ethernet shield(Wiz5500) @ bascom 2.0. : REPLY
Hello uhrmacher
You can find working webservers in the blog section that I have written
you should only need to change the config for the W5500 instead of the W5100
Regards Paul
↧
BASCOM-ARDUINO : arduino mega (2560) + ethernet shield(Wiz5500) @ bascom 2.0. : REPLY
uhrmacher
please update your email address in the forum account settings. if you have no idea, please write to support.
↧
BASCOM-AVR : Bascom and CI SEMTECH sx1276.. sx1278 : REPLY
Hello Robert,
I didn't see the config SPI line, It is normal ?
jp
↧