Posts

How to debug if you have difference in 2 repos that have 7-8 repo in between

 Just download all the repos and check git log or hg log   1st repo HD_R6201 & 2nd repo BBDR2014 the 1st repo has the bug then check the date in between where submissions are missing in 1st repo then goto 2nd repo check all the fixes that have been commited if not then check all intermediate or in between repos or branches Incase of emergency check in 1 repo above HD_R6201 that is HD_R6301 Check the exact scenario must match 

Important mercurial commnads

 hg diff -r <changeset-no1>:<changeset-no1+1> example :- hg diff -r 66237:66238 hg log --keyword "call" (will search all the commits with "call" in discription hg diff -c <commit-id> hg log -r <CS ID> --debug   (to know the commit details and branch name) example:- starting pager for command 'log' changeset: 14986:3b584f4ea27ebe6178c81d74767fe0f24290377b branch: cvp95 phase: public parent: 14985:762a72f7821ca441f5d0a3975eff344dd5a0e8a5 parent: -1:0000000000000000000000000000000000000000 manifest: 14918:d778007144b782255b9b1c0c56bc9a43f635e594 user: crzhang <crystal.zhang@nokia-sbell.com> date: Fri Dec 25 15:14:28 2020 +0800 files: SIP_PAL/pal/callmgnt/pal_callmgnt_wtconnect_state.cpp extra: branch=cvp95 description: BBDPROD-7552:Tight couple ONT IncomingTotalCallTime/TotalCallTime node does not work in call hold scenario

Good tools

OP Auto Clicker ghidra-sre.org SecureCRT  https://crackpur.com/securecrt-crack/ crontab (running program at interval) entr Lauterbach RTLinux Redox os/VxWorks Visual Studio CLion  tftp/ftp/scp ag (silver searcher) - https://www.cyberciti.biz/open-source/command-line-hacks/ag-supercharge-string-search-through-directory-hierarchy/ cscope ctags Mobaxterm Beyond compare/meld Hyperterminal/Tera Term(for modem connection) bitbucket/git/Jira/Confluence powershell can also be alternative of Hyperterminal(https://social.technet.microsoft.com/Forums/ie/en-US/2980f24e-56d1-431f-aedc-811c087b5184/powershell-serial-com-port?forum=ITCG)

Why C is the most powerful language

  Modularity and less keyword unlike other languages that have dedicated keyword for simple math functions,   it has libraries more instead of keywords   that makes it   efficient . Complex Declarations   , using complex declaration you can define any real world entity Storage classes such as extern & register, inline, volatile, const keyword which are low level in nature etc. Direct   mapping of constructs to memory segments Pointers with   Pointer typecasting & treating Function name as pointer ,   i think pointers are useless without pointer typecasting. Function name is treated as pointer in C which makes it very powerful and also pointer arithmetic. Wide varieties of types   from long long to char , floating type such as float or double but has   weak type checking. void * / int * as a generic data storage Use of   expression   in every place whether it’s in   for , while or if for(expression ; expression; e...

Firmware Interview Questions

 He asked a puzzle that you have 500 switches and all are OFF. Now someone came and make all of them ON. Now a second person came and flip all the second switch and then 3rd came and flip all the 3rd switch and so on till 500. So tell me how many switch will be on after completing the entire process. synchronization mechanisms for threads associating a mutex with a condition variable solved it mutex reursive binary semaphore and mutex Clone a linked list into two different linked lists such that one list contains the first half of the existing linked list, in the same order, and the other list contains the other half. Time complexity should be minimum. How would you represent a sparse matrix using minimum space complexity such that all elements can be accessed through their row and column indices? Prepare a STAR matrix parse matrix. C programming to the depth. like triple pointers, linked lists, algorithms etc. 1st F2F was on checking the logical ability and problem solving along w...

Basic Parsing using strtok

  C string.h library provides functionalities for parsing like strtok() string tokenizer is a functionality which will tokenize the string using the delimiter It basically replaces the delimiter string(char *) with '\0' next time we do strtok we give NULL as input instead of char* token with delimiter string.  char *strtok(char *token, char* delimiter);  Usage of strtok in Computer Networks for IP Address Parsing #include <string.h> #include <stdio.h> #include <stdlib.h> int main() {   int val;   char c[64]="192.168.0.0";  // be careful it should be character array not character pointer   char *tok;   tok=strtok(c,".");   while(tok != NULL)   {      val = atoi(tok);      printf("%s %d %x %o\n",tok,val,val,val);      tok=strtok(NULL,".");   } }   Wide application of strtok can be used for questions like:- " I LOVE MY COUNTRY " " COUNTRY MY LOVE I" ...

Linking of Programs using Header

Image
                          Linking of Programs using Header  It's only takes 4 steps to link 2 programs 1) Keep the name of the header and name of the file same 2) Declare all function declarations in the name.h as defined in name.c 3) Now call the header file name.h using #include "name.h" in main.c 4) Compile both the binaries together using gcc command. It is Shows same behavior as in inheritance in C++