OpenSprinkler › Forums › OpenSprinkler Unified Firmware › Question about blank Atmega644 programming…
- This topic has 11 replies, 3 voices, and was last updated 9 years, 5 months ago by Ray.
-
AuthorPosts
-
December 1, 2014 at 9:15 am #34859
RadostinParticipantHi to all!
Is there any tutorial regarding how to program a blank atmega644 whit optiboot or directly the whole hex firmware.I want to build by myself all the hardware…I’ve search all over the place but didn’t find any info about.
I don’t think it will work out of the box trough normal firmware update,because of no bootloader inside the atmega…
So waiting for further steps or instruction how to do it by myself…
thanks in advance for helping me out 😉
December 3, 2014 at 12:48 am #34877
RayKeymasterYou will need an ISP programmer (such as USBasp, USBtiny, AVRisp). Flash the optiboot bootloader to the microcontroller through the ISP pins on the circuit board. Once the bootloader is flashed, you can program the microcontroller through the USB port.
December 3, 2014 at 8:24 am #34885
RadostinParticipantThank you for the answer Ray!
My second question is where can I find latest 2.2u part list(BOM) and if possible smt version also …
Thanks again for help!
December 4, 2014 at 9:18 pm #34903
RayKeymasterThe hardware design files are generally released in Github. Here is the direct link to version 2.2:
https://github.com/rayshobby/opensprinkler/tree/master/OpenSprinkler%20Controller/hardware/v2.2The BOM is not included, but you can generate the BOM from the schematic using the EagleCAD software.
February 19, 2015 at 4:29 am #35606
RadostinParticipantHello again from me!!!
I’ve builded my own opensprinkler hardware based on 2.2 smt variant.Still don’t have usb serial chip CH340G on my board(ENC28J60 also still missing) . I flashed trough ISP directly into the blank atmega644p this file firmware2.1.2.hex using usbtiny programmer and avrdude with this command:avrdude -c usbtiny -p m644p -U flash:w:firmware2.1.2.hex
But after this,nothing happened;( Is this a right procedure or I’m missing something?I didn’t find any info how to flash first the bootloader(optiboot),so i decided to go straight to the firmware…Any help,tutorial will be very helpful.
Thanks in advance!
February 19, 2015 at 8:44 am #35608
RayKeymasterTry this:
avrdude -c usbtiny -p m644p -U lfuse:w:0xFF:m -U hfuse:w:0xD6:m -U efuse:w:0xFF:m
A blank ATmega chip is set to run on internal 1MHz clock. The above sets the fuse bits to use external crystal clock. Since you don’t have CH340G yet, you don’t need to flash the bootloader.February 19, 2015 at 8:53 am #35611
RadostinParticipantThanks Ray,all working now,missed the fuses.Waiting tomorrow for ENC28J60,because now Opensprinkler hangs on Connecting…Some times if i touch with finger some points it goes to the menu…
If you have time,can you tell me how to burn bootloader with avrdude and witch file from where to use?
Thanks again for the support!!!
PS:When I get all things working will post pictures/videos of building the controller,all by myself,except pcb manufacturing;)
March 18, 2015 at 3:05 am #36075
RadostinParticipantHi!
A long awaited usb ic CH340G has arrived.If possible can you guide me please,what I must flash into atmega trough ISP,so in future to use usb for upgrading FW.For now my PC recognizes usb device,drivers are installed,FW update program is recognizing COM port,but can not flash new FW.What bootloader i must use and if possible the command line for avrdude!
Thank you again for helping me out!
March 21, 2015 at 5:47 am #36158
AnonymousInactiveHy,
I would like build a 2.1 hardware version OS, at first I wired in a beardboard just the Atmega644 (I attached that I bulit) and connected wia USB to my PC. the Win says: unknown device, I pushed an released the B2 button, as you offered, but i can’t install the correct USBasp driver
My Atmega644 is brand new, I newer upload any bootloaders.
It’s needed to upload an USBasp bootloader first via ISP, or what can I do for working?
Attachments:
March 21, 2015 at 10:01 pm #36168
RayKeymasterA blank ATmega644 does not come with bootloader, you will need to use an ISP programmer to program a bootloader to it. On the other hand, if you already have an ISP programmer, you can directly program the firmware to the microcontroller without going through OpenSprinkler’s USB port.
April 8, 2015 at 1:53 pm #36563
AnonymousInactiveDear Ray, sorry for late feedback. With your instruction I uploaded the FW. Thanks for your help. If I can, I will help you to translate to hungarian language.
April 9, 2015 at 8:37 am #36583
RayKeymasterOK cool. About translation, sure you can help. The translation is crowdsourced by using Get Localization available at:
http://www.getlocalization.com/OpenSprinkler/
I think Hungarian is already one of the supported languages, but you can help validate the translation. -
AuthorPosts
- You must be logged in to reply to this topic.
OpenSprinkler › Forums › OpenSprinkler Unified Firmware › Question about blank Atmega644 programming…