Comments (7)
Hi,
Yes send the code for interest.
What's the advantage of using ASM over C?
from sevensegmentmodule.
Hi,
Yes send the code for interest.
What's the advantage of using ASM over C?
from sevensegmentmodule.
Advantages are code size and speed, especially for 8-bit pic asm as the instruction set wasn't designed with a compiler in mind. And for simple tasks like multiplexing a display, it allows you to minimize the time spent switching one digit off and the other on.
Attached. Apart from the init code, everything runs inside the interrupt handler:
16F18446_BMD_01_src.asm.txt
16F18446_BMD_01.X.production.hex.txt
from sevensegmentmodule.
from sevensegmentmodule.
It certainly makes sense, and with most other microcontrollers there would be little reason to enter into an assembly solution.
And you are right, the difference in power consumption is negligible. I did test with and without sleep, the current draw difference doesn't even come to a milliamp.
But using a hardware timer in conjunction with sleep allows you to turn the clock speed right up, which benefits my next point.
The main goal here was tightening up the multiplexing routine to vastly reduce dead time when switching between the digits (increasing apparent brightness), as there are multiple ports involved in driving the segments.
from sevensegmentmodule.
from sevensegmentmodule.
Thanks for the info
from sevensegmentmodule.
Related Issues (1)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sevensegmentmodule.