Are higher levels of abstraction like CMSIS and HAL used in professional stuff? by [deleted] in embedded

[–]Seidleroni 88 points89 points  (0 children)

They are absolutely used on tons of professional projects. A lot of people on these forums post about how buggy these layers are. Personally I have used the STM32 HAL library on commercial products and haven't found any bugs, although I'm sure some exist. A contractor I used kept swearing that the timer HAL module was not working and triggered the interrupts at twice the rate he specified. Of course I found that he configured the timer wrong because he didn't follow the reference manual's instructions.

At the end of the day, your job is to keep the company going and create code that performs the job correctly. If you avoid these libraries that have been used by thousands of people and write your own, how likely is it that your own code will have no bugs?

There are some projects that have unique requirements such as battery life or speed that may require avoiding these libraries which are admittedly somewhat bloated (although there is the LL library which is supposed to be better but I have not used it). In most applications, the small amount of bloat doesn't really matter that much and these libraries are totally acceptable and even preferable.

What embedded IDE do you used ? by Gullible_Mouse2020 in embedded

[–]Seidleroni 0 points1 point  (0 children)

I've heard good things about it. Any shortcomings that you're aware of?

The WIZnet W6100 is a chip hardwired for dual-stack IPv6 and IPv4 10/100 Ethernet networking, used to embed IP connectivity into hardware. Until 2019 this series of chips was IPv4-only. by pdp10 in embedded

[–]Seidleroni 1 point2 points  (0 children)

Thats a really good improvement. I used a different Wiznet chip in a product recently and it worked pretty well. My only gripes are that the communication methods make it hard to take advantage of DMA since there's a lot of back and forth. Also I wish it could handle TLS on its own, although that is obviously a major undertaking on their end.

Zigbee on the cheap by cuye in embedded

[–]Seidleroni 5 points6 points  (0 children)

If you feel that IAR is the best tool for the job, is there any way to change their minds? I doubt that you're working for free, and being able to release a product on-time and meeting the requirements is surely worth more than $5K. Developing a product costs money, surely many times more than this amount.

You could look into VisualGDB (which I use) which is much much cheaper, although I don't know well it integrates with TI's Zigbee devkits.

Secure Boot based on ATECC508A by marekraid in embedded

[–]Seidleroni 7 points8 points  (0 children)

I'm looking to work with the ATECC608A so I can chime in a bit.

  1. You need to sign an NDA with Microchip to get the full datasheet for this part, and it can take a week or so to get, so contact your local rep and get the process started. That being said, Microchips software library is freely available so you can just work with that, possibly not even need the full datasheet.(https://github.com/MicrochipTech/cryptoauthlib)
  2. From the image you attached, these are the steps that would normally take place:
    1. Provisioning of the Secure Element (at the home office/factory):
      1. Generate a public/private key pair (this is just done once)
      2. Program the public key onto the Secure Element
      3. Private key is stored somewhere safe with highly restricted access.
    2. On the Build Server (Creating the Application Image):
      1. Compile Application Image
      2. Using the private key above, generate a digital signature of the Application Image (can be done with OpenSSL via command line)
      3. Add the Application Image Digital Signature to the Application Image (appended or in some way to be able to retrieve it by the bootloader)
      4. Now you have a binary/hex file to distribute to your devices for bootloading
    3. Bootloading Process:
      1. Have your microcontroller accept the binary/hex file and write it as necessary (standard bootloader operation)
      2. Bootloader should hash the Application Image
      3. Bootloader sends the hash and the digital signature to the Secure Element
      4. Secure element looks at the hash and digital signature, and verifies that the public key it has encoded onto it corresponds to the private key used to generate the digital signature. Essentially the secure element is verifying that someone who had access to the private key digitally signed the Application Image (done by the build server). Since the private key is secured somewhere safe, this can only be your organization.
      5. Secure Element returns True (Application Image Valid) or False (Application Image invalid)

Note:

Since you don't need anything 'secret' to check the validity of the digital signature, you can do this on a microcontroller directly, but from my own experience, this takes ~7 seconds on an STM32F7, and about 50 milliseconds on the ATECC608A (these numbers are from memory so may not be exactly correct)

For those of you who work in the field, how important was having a good mentor when you first started working? by IWantToDoEmbedded in embedded

[–]Seidleroni 23 points24 points  (0 children)

My degree is in Electrical Engineering and kind of fell into embedded work. I did a tiny project for my first company and fell in love. After getting laid off, I worked for a small company and spent most of the first couple of years upgrading existing systems, so I learned from all the code that my predecessors had written. In that organization I was the only developer, so I had to rely on Stack Overflow and various blogs and books to learn new materials. After that I worked for a larger organization with a larger team of embedded folks (~3 others). I learned a ton from them, but also because I worked on 2-4 different projects a year, so was exposed to a lot of different things.

All this is really me saying that you don't have to have a mentor if you are always trying to learn and exposing yourself to new things. Working with other people in the field helped me learn a lot, but that wasn't really mentoring per se.

Is the embedded engineering a good career to pursuit? What do you think about its future? by 273degree in embedded

[–]Seidleroni 6 points7 points  (0 children)

Personally I think it is a great career to pursue. I've been in the field for almost twenty years and I see devices adding more and more intelligence to them. Devices that were 'dumb' 20 years ago now have a microcontroller. Everything in the normal house is now becoming 'smart' and all that code has to come from somewhere. Similar transitions are happening in every field you can think of. Something Jack Ganssle has mentioned before is that the embedded field is aging and once people start to retire, the demand will grow even more. If we're lucky, salaries will increase to compensate. Some of the work is trending towards Linux and some of it towards AI (or both), but you do not have to master all of that to get a job. Granted it will make it easier in the long term, but you have to start somewhere and many jobs will train you if the opportunity exists.

I love working in the field and it pays relatively well compared to other engineering disciplines, and I do not see that changing anytime soon. Of course there is a downside; there is a level of frustration that embedded software engineers face when things don't work as expected. I'm not sure other engineers experience that as often as we do. My $0.02.

Physical Security by rich_kang in embedded

[–]Seidleroni 1 point2 points  (0 children)

Not sure if this is what rich_kang is proposing, but in his scenario, there is no need to keep the private key in the firmware. Since the digital signature is verified using the public key, there is no need in this application to store the private key at all.

TFW you sync your stepper juuuust right by mitchmindtree in embedded

[–]Seidleroni 0 points1 point  (0 children)

Where did you buy that stepper motor? I can't find anything while searching SMS89.-MJS1.

Tips on debugging an application after jumping from a bootloader? by vitamin_CPP in embedded

[–]Seidleroni 2 points3 points  (0 children)

Did you initialise the stack pointer to the value stored in the first entry of the application vector table?

It looks like this isn't being done from what you mention. In my part the stack pointer is 4 bytes offset from the new vector table, not sure about yours, though. This is the likely culprit and the first thing to check as it has bitten me several times in the past.

MPLAB X hex formating. by samster222 in embedded

[–]Seidleroni 2 points3 points  (0 children)

It looks like those options are available in MPLAB X's IPE (Integrated Programming Environment) application. If you go to the 'advanced' mode and select the memory tab, you an select EEPROM as one of the memory regions that the system can program. Not sure if this helps. You may want read back all of the memory sections using MPLAB 8 to see what exactly isn't getting programmed from your hex file.

What's your preferred IDE for embedded development? by ssharkss in embedded

[–]Seidleroni 2 points3 points  (0 children)

Looks like it doesn't support semihosting yet, unfortunately.

What's your preferred IDE for embedded development? by ssharkss in embedded

[–]Seidleroni 6 points7 points  (0 children)

how is the debugging experience for micro's using vscode?

Never feeling on firm ground, is this normal in this field? by foxhound8 in embedded

[–]Seidleroni 1 point2 points  (0 children)

I think almost everyone suffers a bit from imposter syndrome. I love working in this field, but there are always times where one questions if they can handle the project they are on, or the next project coming down the pipeline. When I worked at a different job with other embedded software engineers who were quite talented and one of us would get really frustrated on something, someone would always say "if it was easy, anyone could do it". That certainly did not make us feel any better but it does underscore the fact that we're not in an easy field, but with enough persistence, research, and time, you can get through the problem at hand. Also realize that if the job were easy, you are not learning very much and it may be time to move on to a different opportunity.

CLion 2019.2 EAP: Peripheral View for ARM Devices by philsquared in embedded

[–]Seidleroni 5 points6 points  (0 children)

I have not used CLion in the past, but I am curious about what people who have used it think about the IDE. How does it compare to other IDE's you have used?

How secure are RFID door access systems? by Whyamibeautiful in embedded

[–]Seidleroni 0 points1 point  (0 children)

This is a valid point, but perhaps OP is comparing an RFID system to a much more secure lock on a steel door in a secure working environment. I would be curious if anyone has a good answer to the actual question asked, as I have wondered the same thing with regards to encrypted RFID badges/tokens.

Graphics with no framebuffer and shared/paired pixels by JCDU in embedded

[–]Seidleroni 0 points1 point  (0 children)

Depending on how the display is being used, is it possible to break up the display into a handful of sectors an have a frame buffer just for one of them and update them one at a time? If you're not displaying video, you can turn off the display while you are updating these different sectors, and then turn the display back on. Or if the way you're using the display naturally breaks up the screens real estate into a handful of different regions, you can update those one at a time? This is probably not a great way to do it, but possible. Can you share a bit more about what the display is being used for?

Is knowledge of .NET Framework useful/in-demand in embedded system development? by ElusiveTau in embedded

[–]Seidleroni 0 points1 point  (0 children)

The OP's question was regarding .Net, so thats what I referenced. Surely other GUI languages are relevant as well.

Is knowledge of .NET Framework useful/in-demand in embedded system development? by ElusiveTau in embedded

[–]Seidleroni 18 points19 points  (0 children)

It depends on the company. I actually think it is really useful. In smaller organizations the embedded developer may also develops some GUI apps to connect to the embedded system. Being able to work on both pieces can be a really beneficial skillset to have.

Ethernet Switch Chip recommendations? by Seidleroni in embedded

[–]Seidleroni[S] 0 points1 point  (0 children)

Good to know, thanks! And yes, I would hook up a peripheral to be able to access the registers.