Author Topic: Understanding on Terminologies  (Read 1337 times)

0 Members and 1 Guest are viewing this topic.

Offline sadasivamASKTopic starter

  • Contributor
  • Posts: 21
  • Country: in
Understanding on Terminologies
« on: April 29, 2022, 06:56:45 am »
Hi,

In Embedded Systems, need understanding on following topics.

1. The term "Modules"?
2. HAL
3. Application Interface and Application Peripheral Interface
4. Purpose of Drivers? without driver cant we access hardware directly?
5. Inline Assembly coding- When it will be used better other than low level coding?
6. What is Host in BLE
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11905
  • Country: us
    • Personal site
Re: Understanding on Terminologies
« Reply #1 on: April 29, 2022, 07:35:06 am »
This sounds like a homework assignment. We generally don't do people's homework.

But also, have you tried googling at all? This is trivial stuff and answers are extremely easy to find.
Alex
 
The following users thanked this post: tooki, sadasivamASK

Offline sadasivamASKTopic starter

  • Contributor
  • Posts: 21
  • Country: in
Re: Understanding on Terminologies
« Reply #2 on: April 29, 2022, 07:40:31 am »
Yeah, as it is. But, in terms of explaining with example. It will give some clarity on these topics.
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11905
  • Country: us
    • Personal site
Re: Understanding on Terminologies
« Reply #3 on: April 29, 2022, 03:44:17 pm »
Google first, describe how you understand those things and we will confirm or correct any inaccuracies. Nobody will be doing a homework for you or acting as your teacher.
Alex
 
The following users thanked this post: tooki, Cubdriver, Neomys Sapiens, sadasivamASK

Online tggzzz

  • Super Contributor
  • ***
  • Posts: 21226
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: Understanding on Terminologies
« Reply #4 on: April 29, 2022, 06:00:05 pm »
In Embedded Systems, need understanding on following topics.

That can be achieved by:
  • doing basic research, probably using google
  • thinking and understanding
  • re-writing the relevant bits in your own words
  • thinking and understanding
  • where your words lead you to believe you don't understand something, think and research
  • if you still don't understand, you will be in a good position to ask a question that can be answered

Master that and you will have learned something that will be useful throughout your life in all sorts of ways.

Yes, that requires hard work. That's life. Deal with it.
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 
The following users thanked this post: tooki, Neomys Sapiens, sadasivamASK

Offline sadasivamASKTopic starter

  • Contributor
  • Posts: 21
  • Country: in
Re: Understanding on Terminologies
« Reply #5 on: June 01, 2022, 04:38:16 am »
Hi,

1. The term "Modules"?
    In terms of SW, Modules are discrete piece of code which can be independent created and maintained to be used in diff. systems. For example, developer may create a module containing a code required to use the soundcard or perform IO on certain type of File System. The module can then be used by any system that needs its functionality.

    In terms of HW, Modules is a independent component that is used as a part of complex systems. For eg, Memory module can connect to computer's Motherboard to operate as a part.


2.  HAL
     HAL layer: If multiple applications requiring soundcard for example, then HAL provides abstraction for accessing the soundcard at
     same time.
     Uses:
     - It provides an abstraction from HW access.
     - So, the application developer no need to focus on HW specific aspects. He can work on only, how to write application for HAL.
     - HAL will take care of HW usage via Driver.

3. Application Interface and Application Peripheral Interface?
    - Its an another layer in SW system. In order to get services like Amazon, Twitter, etc,. in our system, we need APIs.

4. Purpose of Drivers? without driver cant we access hardware directly?
    - Its a layer between HAL and HW. To ease the application programs.
    - If application wants to access HW(Memory) for writing and reading data
    - User can send write() or read() function, that is enough.
    - Driver specific to HW(memory) will handle the functions
    - Inside Driver-> Register Access will occur

5. Inline Assembly coding- When it will be used better other than low level coding?
    Actually, the q is wrong. In what situation, Inline Assembly helps to optimize the code written in C.
    Examples needed?

6. What is Host in BLE?
    Examples needed?

Need ur support and corrections in above understanding.
 

Offline niconiconi

  • Frequent Contributor
  • **
  • Posts: 366
  • Country: cn
Re: Understanding on Terminologies
« Reply #6 on: June 01, 2022, 11:02:34 am »
Quote
1. The term "Modules"?
Basically correct.

Quote
2.  HAL
Basically correct.

Quote
3. Application Interface and Application Peripheral Interface?
    - Its an another layer in SW system. In order to get services like Amazon, Twitter, etc,. in our system, we need APIs.

This is not wrong (it describes why would one use a "web API"), but it missed the point. API in the broadest sense, is a set of standards and conventions that specify how a software module can be accessed/used by a programmer from another part of the system. Examples: if its purpose is to create a process, read or write a file, it's an operating system API ("Win32 API" is a well-known example), if its purpose is sending a post to Twitter via HTTP, it's a type of "web API".
« Last Edit: June 01, 2022, 11:07:12 am by niconiconi »
 
The following users thanked this post: sadasivamASK

Offline PlainName

  • Super Contributor
  • ***
  • Posts: 7508
  • Country: va
Re: Understanding on Terminologies
« Reply #7 on: June 02, 2022, 04:57:28 pm »
Quote
2.  HAL
HAL layer: If multiple applications requiring soundcard for example, then HAL provides abstraction for accessing the soundcard at same time.

I would say that the HAL is nothing to do with multiple access (that would be the responsibility of the driver/API). The HAL is simply a hardware abstraction layer, so it provides a simplified paradigm for higher layers to deal with. For instance, where the setting of some pin may involve a series of register accesses using bit masks to isolate the pin, the HAL would provide what looks like a pin that can be set on or off.
 
The following users thanked this post: tooki, sadasivamASK

Offline RJSV

  • Super Contributor
  • ***
  • Posts: 2757
  • Country: us
Re: Understanding on Terminologies
« Reply #8 on: June 03, 2022, 02:22:39 am »
   I can respond a little, but please also heed the advice coming from others.  I think maybe what is needed from you is a circular, go study an item or two on your list, and, best of all, is when you can come back in with a specific question, and describing where you've gotten snagged on some detail.
Proceeding that way, you can keep your FOCUS; meanwhile you can, periodically, bring your questions.
Especially details, about where you've gotten stuck.
No such thing as a stupid question, according to variable skill level.

   Anyway, I think the coding term 'In-line' refers to little (usually brief) lines of code, that allow quick, simple, and very direct action.  Often that's just one single action that, is either doing very fast/brief, or doing something the high level language cannot.
Maybe not some simple thing, like 'bit-shift', but more like a 'Force Parity Error' diagnostic command, that isn't implemented in the actual host language.
Probability that the above is correct,...maybe 57%.
 
The following users thanked this post: sadasivamASK

Offline sadasivamASKTopic starter

  • Contributor
  • Posts: 21
  • Country: in
Re: Understanding on Terminologies
« Reply #9 on: June 03, 2022, 05:50:23 am »
Hi,

Yes.

Quote
Especially details, about where you've gotten stuck.

I will come up with suitable situations. Thanks for all ur support in this. Understanding wise, I haven't able to get these points, thatswhy i queried this kind of q's. Now, its okay i got clarity.
 

Online CatalinaWOW

  • Super Contributor
  • ***
  • Posts: 5571
  • Country: us
Re: Understanding on Terminologies
« Reply #10 on: June 03, 2022, 04:52:08 pm »
You seem to have gotten the concept generally right.

The specific meaning will depend on context and time.

Take module for example.  Once upon a time the US military though to reduce inventory and logistics problem through implementation of standard electronic modules which they cleverly called SEMs.  These were incredible simple and might include a single flip flop of a high power PNP-NPN transistor pair.

To the designer of urban transportation systems an automobile, a cloverleaf highway intersection, a bridge, a light rail system and an airport might all be considered modules.
 
The following users thanked this post: sadasivamASK

Offline sadasivamASKTopic starter

  • Contributor
  • Posts: 21
  • Country: in
Re: Understanding on Terminologies
« Reply #11 on: June 07, 2022, 04:11:08 am »
Yeah @Catelina. Now, its understandable. Thanks for sharing examples.
 

Offline niconiconi

  • Frequent Contributor
  • **
  • Posts: 366
  • Country: cn
Re: Understanding on Terminologies
« Reply #12 on: June 07, 2022, 06:19:56 am »
Speaking of inline assembly (i.e. mixing assembly code in the middle of a high-level language like C), in my experience the common use cases are:

1. Performance-critical Code. If 90% of your CPU time is spent on an algorithm that must be as fast as possible, it makes sense to rewrite it (or at least the critical inner loop) in assembly. Example: encryption/decryption, compression/decompression, encoding/decoding for images and videos. I have first-hand experience about how cryptography programmers go to great lengths at removing even the last possible CPU cycle from the code, often with extremely convoluted techniques (for starter, https://cryptojedi.org/peter/teaching/ce2020/multiprecision.pdf for example).

2. Code with predictable timings, especially when programming small microcontrollers. For example, when bit-banging GPIO ports or handling interrupt requests, sometimes the operation must be completed within a few microseconds, or, exactly n microseconds. In high-level languages it's often not guaranteed, but in raw assembly you know exactly how many CPU cycles is spent on each instructions (though the situation is much more complicated on modern pipelined, out-of-order CPUs).

3. Directly accessing CPU instructions and registers not available in the high-level language. When you need to call a special instruction or access a register specific to a processor, sometimes it's only possible in assembly (other times, the C compiler has extensions or "Intrinsic Functions", allowing you to access them in C, but even then, assembly is sometimes still more comfortable to work with).
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf