buck

Buck - java.lang.UnsatisfiedLinkError: couldn't find “libjni.so”. How to solve it?

ⅰ亾dé卋堺 提交于 2019-12-05 16:01:30
A runtime exception is happening after executing the command buck install --run demo_app_android following this tutorial and this sample demo Then, the following is shown in console Installing apk on emulator-5554 (null). [-] PROCESSING BUCK FILES...FINISHED 0.0s [100%] 🐌 File removed [-] DOWNLOADING... (0.00 B/S AVG, TOTAL: 0.00 B, 0 Artifacts) [-] BUILDING...FINISHED 0.8s [100%] (1/1 JOBS, 1 UPDATED, 0 [0.0%] CACHE MISS) [+] INSTALLING...2.1s Successfully ran install apk //android:demo-app on 1 device(s) Starting activity com.facebook.buck.demo/.App... Successfully ran start activity on 1

BUCK转换电路的工作原理

蹲街弑〆低调 提交于 2019-12-05 13:47:10
开关电源(Switching Mode Power Supply)即开关稳压电源,是相对于线性稳压电源的一种的新型稳压电源电路,它通过对输出电压实时监测并动态控制开关管导通与断开的时间比值来稳定输出电压。 由于开关电源效率高且容易小型化,因此已经被广泛地应用于现代大多数电子产品中。如果说每个现代家庭都至少有一个开关电源都不为过,如电视机(彩色的)、电脑、笔记本、电磁炉等等内部都有开关电源,虾米?这些东西你们家都没有?我去!那手机有没有?手机充电器也是一个小型的开关电源,中招了吧!手机也没有,那就是古代家庭了,忽略之! 如下图所示为线性稳压电源电路的基本原理图: 之所以称其为线性电源,是因为其稳定输出电压的基本原理是:通过调节调整管(如三极管)的压降VD来稳定相应的输出电压VO,也因调整管处于线性放大区而得名。如果某些因素使得输出电压VO下降了,则控制环路降低调整管的压降VD,从而保证输出电压Vo不变,反之亦然,但这样带来的缺点是调整管消耗的功率很大,使得该电路转换效率低下,当然,线性电源的优点是电路简单,纹波小,但是在很多应用场合下,转换效率才是至关重要的。 为了进一步提升稳压电路中的转换效率,提出用处于开关状态的调整管来代替线性电源中处于线性状态中的调整管,而BUCK变换器即开关电源基本拓扑之一,如下图所示: 其中,开关K1代表三极管或MOS管之类的开关管(本文以MOS管为例)

How to install delete-project plugin in gerrit?

匿名 (未验证) 提交于 2019-12-03 02:06:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 由 翻译 强力驱动 问题: I want to install delete-project plugin to my gerrit server. As per the latest version, I should clone it from google source and use buck build. I cloned it and my buck is also ready. What are the steps to be followed to build the delete project plugin and add it to my gerrit server. I tried buck build . in the cloned source of delete-project. But, I am getting the following error Traceback ( most recent call last ): File "/home/gerrit/buck/src/com/facebook/buck/parser/buck.py" , line 872 , in main () File "/home/gerrit/buck/src

C++ array is not empty where it should be

匿名 (未验证) 提交于 2019-12-03 01:09:02
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I'm trying to write a hash map with a dynamic array that stores a set of pointers to a linked list struct. I've been running into some strange memory issues. It seems like there are pointers in my array that shouldn't be. I get an error where even though the index that should be generated from the single insert I'm doing is 16, as I loop through the array, there are some non-zero items: start 16 //(output of index from insert) dumbtest //(get of nonexistent key) 0 // result of get of non-existent key HashTable: 0 0x0-- 0x0 1 0x0-- 0x0 2 0xeb

ONOS-Buck编译常见问题总结

匿名 (未验证) 提交于 2019-12-03 00:18:01
1、onos中的命令找不到(mcis onos-karaf cbb-package …) 原因 : 环境变量配置有问题 解决 : 修改对应的环境变量(这些命令都是在onos的目录下面的,所以需要将onos的环境变量添加进.bashrc中) export ONOS_ROOT= $HOME /onos1. 8.2 source $ONOS_ROOT /tools/dev/bash_profile 2、控制器启动之后设备报不上来,查看日志有 address already in use 这样的报错信息 原因 : 端口被占用 解决 : 先查询占用端口的进程,被占用的端口可能是6653或者6633,通过如下命令查询 netstat -ap | grep 6653 查到对应的进程后可通过如下命令将进程kill(pid为查询到的进程id) sudo kill pid 1、关于从github上新下载的代码需要编译通过参考文档 2、从svn上下载的代码编译通过,运行报onos-core-dist或者onos-core-serializers的错误 原因: 为了能让cbb中的序列化模块很好的覆盖onos中的模块,在上传代码的时候将onos中的序列化模块注释了。 解决: 如果要运行onos的代码,可以在 features/BUCK 文件中将被注释的onos-core-serializers模块注释取消

PNP晶体管:特性和应用

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-30 13:20:41
  您可能很清楚,现代电气工程,实际上是整个现代世界,与称为晶体管的设备密不可分。这些组件既可用作开/关开关,也可用作放大器。虽然场效应晶体管目前在电子领域占主导地位,但原始晶体管是双极晶体管,很快就会有第一个双极结型晶体管或BJT。   BJT有两种基本形式:NPN和PNP。这些字母指的是正掺杂半导体层和负掺杂半导体层的排列,如下图所示:   请注意,彩色PNP和NPN图是简化的,不能反映集成电路BJT的实际物理配置。   NPN与PNP:为什么PNP晶体管很重要   根据我的经验,NPN晶体管比PNP花费更多时间。想到这一点的几个原因:   NPN晶体管的电压和电流特性(至少在我看来)更加直观。   当需要开关或驱动电路时,NPN为数字输出信号(例如微控制器产生的控制信号)提供了更直接的接口。   NPN实际上在重要方面优于PNP。这导致了NPN的特别主导地位,因为BJT必须与MOSFET竞争,BJT团队在向比赛发送NPN时更容易获胜。笔者这个2009年加州大学伯克利分校的文件,胡正明,走得更远,他说的,因为这种情况,即较高的NPN性能和MOSFET的-BJT的普遍倾向于认为是“几乎完全是NPN型的。”   因此,我们不能否认PNP不太常见,并且通常不太理想 - 但这并不意味着我们应该忽略它们。本文的其余部分将讨论PNP特性和应用程序。   电荷载体:电子与空穴   如上所示

How can I use buck to build react-native apps for both iOS and Android

人盡茶涼 提交于 2019-11-30 03:47:47
Buck sounds like a great tool for both iOS and Android projects but I have not been abel to find any information on how to use it for react-native projects. Update Looks like there is some work being done on this but it may not be recommended yet. https://github.com/facebook/nuclide/issues/31#issuecomment-164897170 https://github.com/facebook/buck/tree/master/test/com/facebook/buck/js Update 2 Product Pains link https://productpains.com/post/react-native/add-buck-as-a-build-option Update 8/6/2017: I tried following my steps below for integrating React Native into an iOS app with Buck but I ran

How can I use buck to build react-native apps for both iOS and Android

好久不见. 提交于 2019-11-29 00:57:01
问题 Buck sounds like a great tool for both iOS and Android projects but I have not been abel to find any information on how to use it for react-native projects. Update Looks like there is some work being done on this but it may not be recommended yet. https://github.com/facebook/nuclide/issues/31#issuecomment-164897170 https://github.com/facebook/buck/tree/master/test/com/facebook/buck/js Update 2 Product Pains link https://productpains.com/post/react-native/add-buck-as-a-build-option 回答1: Update

数据库怎么支持数据无限增长?(长期更新)

╄→гoц情女王★ 提交于 2019-11-28 02:43:10
可扩展是服务器开发的一个重要的问题。 一个系统的可扩展包括好几个方面,在我看来,数据库可扩展几乎是其中最重要的一个了。 主要体现在两方面,1. io可扩展,iops要跟得上业务的需求,2.存储可扩展。 问题1:假设我有张用户道具表,用户不断增加,每个人有n个道具(n有上限,100个),平均n值为50,db要怎么支持? 如果我用mysql,要怎么做,单表承受不了吧?如果我用mongodb,要怎么做, 单个collection够不够? 答:如果使用mysql,两个方案,如果uid为自增id,那么可直接按号段范围分表,每n个用户一张表,如果uid非自增而是一些字符之类的,那么crc32(uid) % x,x即为分表个数。 问题2:如果问题1里面的n是无限的? 答:这个就麻烦了,我首选mongodb,单个文档有16MB的上限,假设我们只使用10MB,单个道具占用空间为id+cnt,共16字节,那么单个文档可以存储655360个道具, 虽然问题里的n是无限,但现实不太可能达到65w这么多。 如果真有这么多,怎么办?手工的分buck,每个文档为一个buck,buck有个id(1,2,..),个数,道具特别多的人,可以有好几个buck。 ----------------------------------------------------- 更新2019.8.21 近来研究db比较多