Viewing 17 posts - 41 through 57 (of 57 total)
  • Learning to "code"
  • molgrips
    Free Member

    😆

    GrahamS
    Full Member

    Very limited memory, even a limited number of variables and no arrays on some systems, and need to use assembler to get it to do anything unauthorised – you kiddies don’t know how easy you have it

    My day job is programming embedded systems with cheap micros in them.

    Not unusual for us to be writing complete systems (i.e. including an “operating system” and “drivers”) that run on less than 8KB of RAM, 32KB of ROM and a bit of flash.

    Always an eye-opener for engineers that are used to writing code on PCs 🙂

    mikewsmith
    Free Member

    I am not a coder or programmer but I have to code and program.
    From my experience you can’t really teach how to because that is already built in to your style of thinking.
    Problem Solver
    Logical
    Systematic
    go for it

    Language is about the learning and in some ways the hoop jumping, met loads who could replicate what they had done etc. but few who had the ability to solve a problem.

    Fresh Goods Friday 696: The Middling Edition

    Fresh Goods Friday 696: The Middlin...
    Latest Singletrack Videos
    bencooper
    Free Member

    32KB? You were lucky. I wrote a robot controller on a Sharp pocket computer which could only have 256 lines of code, and had to control everything by hacking the custom thermal printer port 😀

    mrmonkfinger
    Free Member

    256 lines of code? Always said it were a long way to go for loaf of bread. Hamlet cigars. Jumpers for goalposts. Isn’t it? Wasn’t it? Eh?

    Oh, and what mikewsmith said. The problem solving analytical stuff. It helps to be able to be able to hold a big pile of details in your head in one go, to form internal representations of systems and their behaviour, to be mildly autistic, to learn written languages quickly, and to like Red Dwarf. I never met an programmer who didn’t like Red Dwarf.

    Cougar
    Full Member

    Wish I still had my old ZX Spectrum+ 128k. I wrong many a game on that – very fond memories. Would they work on a modern TV?

    The “Toastrack” 128 goes for silly money these days. You’d be better off with a +2 or similar.

    There’s a very simple “composite mod” you can do on the old rubber-key. Basically you bypasses the TV modulator, it’s a single wire. I think on the 128s you can get a cable which gives you S-Video or some such (I’d have to check to be 100% certain). But, yes, is the short answer.

    Cougar
    Full Member

    I never met an programmer who didn’t like Red Dwarf.

    So what is it?

    mikewsmith
    Free Member


    cant find a pic of the snooker with planets

    canopy
    Free Member

    😯

    fifeandy
    Free Member

    My day job is programming embedded systems with cheap micros in them.

    Not unusual for us to be writing complete systems (i.e. including an “operating system” and “drivers”) that run on less than 8KB of RAM, 32KB of ROM and a bit of flash.

    Always an eye-opener for engineers that are used to writing code on PCs

    Similar, I was working on a ‘quick’ update to a legacy product designed to sell it into a new market last week. Required me to increase the size of an array by 30 bytes – unfortunately this meant I ran out of RAM and spent the remainder of the day grinding through the code base looking for variables that could be sacrificed to find the 8 bytes I needed.

    Of course as is the nature of such things, when completed and sent to customer for field trial they decided what they had requested wasn’t what they wanted afterall 😕

    andytherocketeer
    Full Member

    run on less than 8KB of RAM, 32KB of ROM

    in our case the requirements were typically like that, but including a 100% overhead (so 4K/16K with 4K/16K spare for patches and future improvement).

    People seem to compare Arduino and Pi but they are very different, other than Arduino attempting to promote proper clean and fancy high level programming of embedded devices, with libraries and OOP, and all the memory hogging, and steering clear of the low level register stuff that gets you lots of memory and performance back. And Pi using Python as the recommended language, presumably with similar levels of high-levelness.

    For a beginner language, I’d choose Python, but it is a bit “weird”.

    GrahamS
    Full Member

    Arduino attempting to promote proper clean and fancy high level programming of embedded devices, with libraries and OOP, and all the memory hogging, and steering clear of the low level register stuff that gets you lots of memory and performance back

    Getting well off-topic now but, you don’t have to use Arduino like that, you can use Atmel Studio instead of the Arduino IDE and write to the registers directly instead of using libraries.

    Handy if you need to save space, improve performance or timing accuracy.

    [video]https://www.youtube.com/watch?v=648Tx5N9Zoc[/video]

    jimdubleyou
    Full Member

    I’d choose Python, but it is a bit “weird”.

    Especially if somebody has run it though one of these!

    http://pyob.oxyry.com/

    😛

    andytherocketeer
    Full Member

    Getting well off-topic now but, you don’t have to use Arduino like that, you can use Atmel Studio instead of the Arduino IDE and write to the registers directly instead of using libraries.

    Yup. Agree there, and is what I do (but not Atmel Studio, since that’s not on Linux). Arduino “IDE” also secretly adds in a few things for your convenience, but inconsistently.

    Was referring more towards the way that the Arduino project aim their products, and the intended audience (relative beginners, and simple tasks).

    I would say that for someone that’s never coded before, then the Arduino way is going to be better than the raw AtmelAVR way, even though you can do both in the same program. But then I started out programming Z80 aged 14, after learning Link380z basic aged 13, so the hard way is not impossible.

    UrbanHiker
    Free Member

    hijack

    Those of you programming low end embedded stuff, are you permanent or contractors? In a similar field and looking at stretching my legs from this office. Interested to hear what sort of thing is out there.

    /hijack

    And to the OP, if you’ve never done coding before, I would recommend https://learnpythonthehardway.org
    Its really very good. It holds your hand all the way, even teaching you about basic tools that you’ll need like text editors. By the end of you can do simple web pages etc.

    GrahamS
    Full Member

    Those of you programming low end embedded stuff, are you permanent or contractors?

    Permy. Been with my company for 12 years.

    Our company basically does development work for other companies, so I do get a lot more variety than many other people in permy roles – including spending a few years working on-site at other companies.

    I have a mate that does contracting for embedded stuff though – that’s definitely an option if you have the flexibility and skills. His typical contracts are on a 6 month basis then rolling from there.

    molgrips
    Free Member

    Contracting is a double-edged thing though. On the one hand, you get different workplaces and perhaps different opportunities. But it’s true that you get employed to do one thing and you have to be lucky to get put onto something else.

    You don’t generally employ a brickie and then pay to help train her up to be an architect, do you? No, you want bricks laid.

Viewing 17 posts - 41 through 57 (of 57 total)

The topic ‘Learning to "code"’ is closed to new replies.